package com.itheima.day20.demo07;

import java.util.function.Predicate;

public class PreducateDemo01 {
    public static void main(String[] args) {
        String s = "wangjie";
        boolean boo = checkString(s, e -> e.contains("a"), e -> e.length() > 5);
    }

    public static boolean checkString(String str, Predicate<String> one, Predicate<String> two) {
        return one.or(two).test(str);
    }
}
